package com.api.entity;

import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 用户表
 * </p>
 *
 * @author author
 * @since 2024-08-10
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("tb_user")
public class User extends GlobalEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(description = "编号")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "账号")
    private String userName;

    @Schema(description = "昵称")
    private String nickName;

    @Schema(description = "密码")
    private String password;

    @Schema(description = "头像")
    private String profile;

    @Schema(title = "工资")
    @NotBlank(message="工资不能为空")
    private Double salary;

    @Schema(title = "学校")
    @NotBlank(message="毕业学校不能为空")
    private String university;


    @Schema(title = "岗位")
    @NotBlank(message="岗位学校不能为空")
    private String post;


    @Schema(description = "身份 0 普通用户 1 超级管理员 2 发布者 ")
    private Integer role;




}
